call rtezrequest('If you changed the path,'||LF||'you must restart the daemon.','Okay,!','EZCron ERROR','rt_reqpos = reqpos_centerscr rtez_flags=ezreqf_centertext',)
end
call prefs()
end
end
datefields:
do forever
call waitpkt('DATEWINPORT') /* Wait for a message from Varexx */
packet = getpkt('DATEWINPORT') /* Get the message */
if packet ~= '00000000'x then do /* This is not a null message */
class = getarg(packet) /* Get the information about the message */
type = word(class, 1)
msg = substr(class, 11,25)
if class = once then field = Date(USA)
if class = daily then call daterange('daily')
if class = monthly then field = 'Monthly-'right(date(S),2) /* Monthly-13 */
if class = sunday then field = 'Sunday'
if class = monday then field = 'Monday'
if class = tuesday then field = 'Tuesday'
if class = wednesday then field = 'Wednesday'
if class = thursday then field = 'Thursday'
if class = friday then field = 'Friday'
if class = saturday then field = 'Saturday'
if class = sunday then field = 'Sunday'
if class = weekdays then field = 'Weekdays'
if class = weekends then field = 'Weekends'
if class = every_nn_dd then field = 'Every_3_Fri'
if class = dspecial then call daterange('##/##/##')
if class = 'CLOSEWINDOW DateWindow' then do
hide
address value host
call waitforpkt()
return
end
if field ~= '' then call fillindate()
return
end
end
daterange:
hide
address value host
settext event_date arg(1)
set startdate enddate enable
settext startdate '--/--/--'
settext enddate '--/--/--'
call waitforpkt()
return
timefields:
do forever
call waitpkt('TIMEWINPORT') /* Wait for a message from Varexx */
packet = getpkt('TIMEWINPORT') /* Get the message */
if packet ~= '00000000'x then do /* This is not a null message */
class = getarg(packet) /* Get the information about the message */
type = word(class, 1)
msg = substr(class, 11,25)
if class = timeonce then field = LEFT(time('N'),5)
if class = minute then field = 'Minute'
if class = five_min then field = 'Five_Min'
if class = ten_min then field = 'Ten_Min'
if class = quarterly then field = 'Quarterly'
if class = twenty_min then field = 'Twenty_Min'
if class = thirty_min then field = 'Thirty_Min'
if class = hourly then field = 'Hourly'
if class = shour then field = '##:'substr(time('N'),4,2)
call rtezrequest('EZCron has exited with an error'||LF||'Line' SIGL ERRORTEXT(errorrc),'Okay!','EZCron FATAL ERROR','rt_reqpos = reqpos_centerscr rtez_flags=ezreqf_centertext',)
call exiting()
exiting:
hide unload /* Hide the window and unload the gui */